package aop.xyz.myapp.account;

import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import aop.xyz.myapp.domain.account.User;

@Aspect
public class BeforeAdvice {
	public static final Logger log = LoggerFactory.getLogger(BeforeAdvice.class);
	public static String CMNTS = "Modified by @Before advice";
	
	@Before("aop.xyz.myapp.account.SystemArchitecture.delUserByBean() && " + "args(user, ..)")
	public void setName(User user){
		user.setComments(CMNTS);
		log.debug("@Before advice was executed.");
	}
}
